import { reqUserPlaylist } from "@/api"

const state={
    userPlaylist:{
        playlist:[]
    }
}

const mutations={
    USERPLAYLIST(state, data){
        state.userPlaylist = data
    }
}

const actions = {
    async userPlaylist({commit}, uid){
        let result = await reqUserPlaylist(uid)
        if(result.code == 200){
            commit('USERPLAYLIST', result)
        }
    }
}

const getters = {}

export default {
    state,mutations, actions, getters
}